package com.wn.cleandemo.junk.bean;

import androidx.annotation.Nullable;


import java.io.File;

public class PathBean {
    protected String name = "";
    protected String path = "";
    protected long size = 0;

    public PathBean(@Nullable File file) {
        if (null != file && file.exists()) {
            name = file.getName();
            path = file.getAbsolutePath();
            // todo young 后续补充
//            size = FileSizeHelper.getDirSizePartDeep(file);
        }
    }

    public void updateFile(@Nullable File file) {
        if (null != file && file.exists()) {
            name = file.getName();
            path = file.getAbsolutePath();
            // todo young 后续补充
//            size = FileSizeHelper.getDirSizePartDeep(file);
        }
    }

    public String getName() {
        return name;
    }

    public String getPath() {
        return path;
    }

    public long getSize() {
        return size;
    }

    public void setSize(long size) {
        this.size = size;
    }

    public void setName(String name) {
        this.name = name;
    }

    public void setPath(String path) {
        this.path = path;
    }
}
